package com.cn.serverline.lineicp.productionLine.enums;

import lombok.Getter;

/**
 * 工序物料类型枚举
 *
 * @author Gmr
 * @since 2024/7/31
 */
@Getter
public enum ProcessMaterialTypeEnum {

	AUXILIARY_MATERIALS("辅助材料"),
	CONSUMABLES("消耗材料"),
	SPARE_PARTS("零组件");

	private final String type;

	ProcessMaterialTypeEnum(String type) {
		this.type = type;
	}

	public static boolean validateType(String type) {
		for (ProcessMaterialTypeEnum value : ProcessMaterialTypeEnum.values()) {
			if (value.getType().equals(type)) {
				return true;
			}
		}
		return false;
	}
}
